home *** CD-ROM | disk | FTP | other *** search
/ Software Vault: The Diamond Collection / The Diamond Collection (Software Vault)(Digital Impact).ISO / cdr28 / par300.zip / EXAMPL13.STX < prev    next >
Text File  |  1995-04-06  |  2KB  |  25 lines

  1. ;C
  2. ┌─────────────────────────────────────────────────────────────────────────────┐
  3. │ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░    EXAMPLE #13    ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ │
  4. └─────────────────────────────────────────────────────────────────────────────┘
  5. ┌─────────────────────────────────────────────────────────────────────────────┐
  6. │                                                                             │
  7. │  THE INPUT FILE:  This is the same input file we used in Example #4 -- a    │
  8. │                   list of invoices for a computer store.                    │
  9. │                                                                             │
  10. │  WHAT WE WANT:    We want to convert the data into an 80-character fixed-   │
  11. │                   record-length file.  This means that we will not have     │
  12. │                   any carriage returns or line feeds in the output file.    │
  13. │                                                                             │
  14. │  HOW WE DO IT:    We set a flag variable (named "process") to enable the    │
  15. │                   output once we're past the headings.  When the flag is    │
  16. │                   set, we pad each line to 80 characters (using the PAD     │
  17. │                   command), and send the data to the output file, using     │
  18. │                   the OUT command.  (We do not use OUTEND, since that       │
  19. │                   places an end-of-line [carriage return/linefeed] after    │
  20. │                   the output line.)                                         │
  21. │                                                                             │
  22. └─────────────────────────────────────────────────────────────────────────────┘
  23.  
  24. ;P
  25.